import time
st = time.time()

fenzi = 3
fenmu = 2
result = 0
for i in range(1000):
    if len(str(fenzi))>len(str(fenmu)):
        result += 1
    ori_fenmu = fenmu
    fenmu = fenmu + fenzi
    fenzi = fenmu + ori_fenmu

print(result)

print(time.time()-st)